<!doctype html>
<html>

<head>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0" />
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <link rel="stylesheet" type="text/css" href="css/aui.css" />
    <style>
        header #more {
            position: absolute;
            right: 1rem;
        }
    </style>
</head>

<body>
    <header class="aui-bar aui-bar-nav" id="aui-header">
        <div class="aui-title">校园导游</div>
        <i id="more" class="aui-iconfont aui-icon-more" onclick="funActionSheet()"></i>
    </header>
</body>
<script type="text/javascript" src="script/api.js"></script>
<script type="text/javascript">
    apiready = function() {
        api.parseTapmode();
        var header = $api.byId('aui-header');
        $api.fixStatusBar(header);
        var headerPos = $api.offset(header);
        var body_h = $api.offset($api.dom('body')).h;
        api.openFrame({
            name: 'entrance_main',
            url: './html/entrance_main.html',
            bounces: true,
            rect: {
                x: 0,
                y: headerPos.h,
                w: 'auto',
                h: 'auto'
            }
        })
    };

    function funActionSheet() {
        api.actionSheet({
            title: '更多选项',
            cancelTitle: '取消',
            buttons: ['校园编辑登录', '注销']
        }, function(ret, err) {
            if (ret.buttonIndex == 1) {
                api.openWin({
                    name: 'editor_login',
                    url: './html/editor_login.html'
                });
                api.closeWin();
            }
        });
    }
</script>

</html>
